window = global
delete global
delete Buffer;
document = {};

window.CanvasRenderingContext2D = function () {
}
window.HTMLCanvasElement = function () {
}

navigator = {
    appCodeName: "Mozilla",
    appName: "Netscape",
    appVersion: "5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/109.0.0.0 Safari/537.36",
    userAgent: "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/109.0.0.0 Safari/537.36",
    webdriver: false
}

location = {
    "ancestorOrigins": {},
    "href": "https://www.xiaohongshu.com/explore/66b0c48000000000050217a6?xsec_token=AB8gToc_XuVKsYYPRlt3s2FcgG5-CbzML5QOnau8OCYxw=&xsec_source=pc_feed",
    "origin": "https://www.xiaohongshu.com",
    "protocol": "https:",
    "host": "www.xiaohongshu.com",
    "hostname": "www.xiaohongshu.com",
    "port": "",
    "pathname": "/explore/66b0c48000000000050217a6",
    "search": "?xsec_token=AB8gToc_XuVKsYYPRlt3s2FcgG5-CbzML5QOnau8OCYxw=&xsec_source=pc_feed",
    "hash": ""
}

screen = {
    "availHeight":834,
    "availLeft":0,
    "availTop":0,
    "availWidth":1536,
    "height":1536,
    "width":1536
}
window.openDatabase = function (){}
window.AudioContext = function (){}
window.devicePixelRatio = 1.25
canvas = {
    getContext:function () {}
}
document.createElement = function (ele) {
    if (ele == "canvas"){
        return canvas;
    }else if (ele == "div"){
        return {}
    }else if (ele == "h3"){
        return {}
    }
    //根据需要来补充标签返回对象

}
document.documentElement = function (){}

window._webmsxyw = function (){}
window.localStorage = {
    getItem: function () {
    }
}

document.cookie = 'webId=6222916495b442ccf5a6cfd646f35c51; abRequestId=6222916495b442ccf5a6cfd646f35c51; a1=19057d10212a4o58wp1kcsxl6laj4h69sqehc4ltf30000417643; gid=yj82WfyyJ0Myyj82Wfy8JA41yJ04l2YEUyTSd9iMC1K10xq8V4xKjS8884yWK4q8dY8KjKS8; access-token-zhaoshang.xiaohongshu.com=customer.gaia.AT-68c517399849237967017757frwcrbbrwkvuylhj; access-token-zhaoshang.beta.xiaohongshu.com=customer.gaia.AT-68c517399849237967017757frwcrbbrwkvuylhj; webBuild=4.28.4; xsecappid=xhs-pc-web; websectiga=59d3ef1e60c4aa37a7df3c23467bd46d7f1da0b1918cf335ee7f2e9e52ac04cf; sec_poison_id=7f08ce78-dc8d-477f-bf2f-bf6e499f657b; unread={%22ub%22:%2266ad852d0000000027013153%22%2C%22ue%22:%226697bee2000000002500095a%22%2C%22uc%22:28}'

// function SetProxy(proxyObjs) {
//     for (let i = 0; i < proxyObjs.length; i++) {
//         const handler = `{
//           get: function(target, property, receiver) {
//           if (property!="Math" && property!="isNaN"){
//              if (target[property] && typeof target[property] !="string" &&  Object.keys(target[property]).length>3){
//               }else{
//             console.log("方法:", "get  ", "对象:", "${proxyObjs[i]}", "  属性:", property, "  属性类型：", typeof property, ", 属性值：", target[property]);}}
//             return target[property];
//           },
//           set: function(target, property, value, receiver) {
//             console.log("方法:", "set  ", "对象:", "${proxyObjs[i]}", "  属性:", property, "  属性类型：", typeof property, ", 属性值：", value, ", 属性值类型：", typeof target[property]);
//             return Reflect.set(...arguments);
//           }
//         }`;
//         eval(`try {
//             ${proxyObjs[i]};
//             ${proxyObjs[i]} = new Proxy(${proxyObjs[i]}, ${handler});
//         } catch (e) {
//             ${proxyObjs[i]} = {};
//             ${proxyObjs[i]} = new Proxy(${proxyObjs[i]}, ${handler});
//         }`);
//     }
// }
//
// SetProxy(['window', 'document', 'location', 'navigator', 'history', 'screen', 'localStorage', 'sessionStorage'])
